package com.million.orderservice.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.million.orderservice.client.UcenterMemberClient;
import com.million.orderservice.entity.Order;
import com.baomidou.mybatisplus.extension.service.IService;
import com.million.orderservice.entity.vo.OrderInfoVo;
import com.million.orderservice.entity.vo.QueryOrder;

import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 * 订单 服务类
 * </p>
 *
 * @author 十麓
 * @since 2022-04-09
 */
public interface OrderService extends IService<Order> {

    //根据课程id生成订单接口 返回订单号
    String addOrderInfo (String courseId,String jwtTokenId);

    //根据订单号 得到订单的信息
    Order getOrderInfo (String orderNo);

    //根据课程id 和用户id 查询订单状态
    boolean selectOrderStatus (String courseId, String memberId);

    //分页条件查询订单信息
    Page<OrderInfoVo> queryOrderPage (Page<OrderInfoVo> orderInfoVoPage, QueryOrder queryOrder);

    //根据订单号删除订单信息 包括删除订单日志
    void deleteOrderInfo (String orderNo);

}
